Title Banner

Previous Book Contents Book Index Next

Inside Macintosh: QuickDraw GX Printing Extensions and Drivers /
Chapter 4 - Printing Messages / Printing Messages Reference
Printing Messages / Vector Imaging Messages


GXVectorLoadPens

QuickDraw GX sends the GXVectorLoadPens message when drawing with the pens currently in the carousel is finished and it is time to move on to the next carousel. You can override the GXVectorLoadPens message to inform QuickDraw GX of the number and position of pens in the plotter. Your override of the GXVectorLoadPens message must match the following formal declaration:

OSErr MyVectorLoadPens (gxPenTableHdl penTable,
                     long *shapeCounts, Boolean *penTableChanged);
penTable
A handle to the pen table. This structure is described in the section "Vector Pen Table Structure" beginning on page 4-34.
shapeCounts
A pointer to an array of shape counts that corresponds to the pens in the pen table.
*penTableChanged
A pointer to a Boolean value. On return, the value is true if the pen table is modified and false if it remains the same.
function result
An error code. The value noErr indicates that the operation was successful.
DESCRIPTION
QuickDraw GX's default implementation of the GXRenderPage message for the vector imaging system sends the GXVectorLoadPens message when all imaging has taken place for the pens in the current pen carousel and it is time to move on to the next carousel. You can use the GXVectorLoadPens message to prompt the user to change pens loaded in the carousel.

The default implementation of this message does nothing. Your override of GXVectorLoadPens needs to mark all of the currently loaded pens as not loaded and prompt the user to install the new pen carousel. You then update the positions of the pens in the pen table to reflect their positions in the plotter. If you do not override this message, the number of pens in the pen table must be the same as what is currently loaded in the carousel.

Note
The GXVectorLoadPens message should only update the pen position field of the pens. It should not rearrange pens or remove, add, or change any other fields of the pen table.
SPECIAL CONSIDERATIONS
You never send the GXVectorLoadPens message yourself.

You always totally override the GXVectorLoadPens message.

RESULT CODES
gxSegmentLoadFailedErrA required code segment could not be found,
or there was not enough memory to load it.
gxPrUserAbortErrThe user has canceled printing.
gxInvalidPenTableThe specified pen table is not valid.
SEE ALSO
The GXRenderPage message is described on page 4-96.

The vector pen table structure is described on page 4-34.


Previous Book Contents Book Index Next

© Apple Computer, Inc.
7 JUL 1996




Navigation graphic, see text links

Main | Page One | What's New | Apple Computer, Inc. | Find It | Contact Us | Help